package ro.prjmanager.service;

import ro.prjmanager.core.service.AbstractService;
import ro.prjmanager.core.service.Service;
import ro.prjmanager.dao.FixedComponentsDao;
import ro.prjmanager.model.FixedComponents;

import java.util.List;


public class FixedComponentsService extends AbstractService<FixedComponents,Integer> implements Service<FixedComponents,Integer> {



    public void create(FixedComponents user){
        dao.create(user);
    }


    public void delete(Integer id){
        FixedComponents delObj =new FixedComponents();
        delObj.setId(id);
        dao.delete(delObj);
    }

    public FixedComponents load(Integer id){
         return dao.find(id,false);
    }

    public List<FixedComponents> listPag(int startPage,int resPerPage){
          return dao.listPag(startPage, resPerPage);
    }

    public List<FixedComponents> listPagFilter(int startPage,int resPerPage,String filter){
          return dao.listPagFilter(startPage, resPerPage, filter);
    }

    public int no(String filter) {
        return dao.no(filter);
    }

    public void update( FixedComponents entity) {
        dao.update(entity);
    }

    public List<FixedComponents> listPag(int startPage, int resPerPage, String orderCol, boolean asc, Object... otherItems) {
        return dao.listPag(startPage, resPerPage,orderCol,asc, otherItems);
    }

    public List<FixedComponents> list() {
        return dao.findAll();
    }
    
}
